package org.ybxb.demo.user.controller;


import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import org.ybxb.demo.user.entity.User;
import org.ybxb.demo.user.service.IUserService;

import javax.annotation.Resource;
import java.util.List;

/**
 * <p>
 *  前端控制器
 * </p>
 *
 * @author ybxb
 * @since 2024-05-29
 */
@RestController
@Api(tags = "用户管理")
@RequestMapping("/api/user")
public class UserController {

    @Resource
    private IUserService userService;

    @GetMapping("/list")
    @ApiOperation(value = "用户列表")
    public List<User> queryList() {
        return userService.list();
    }

}
